"""Module definition for rules_d."""

module(
    name = "rules_d",
    version = "0.4.0",
    compatibility_level = 1,
)

bazel_dep(name = "bazel_lib", version = "3.0.0")
bazel_dep(name = "bazel_features", version = "1.32.0")
bazel_dep(name = "bazel_skylib", version = "1.8.1")
bazel_dep(name = "package_metadata", version = "0.0.5")
bazel_dep(name = "platforms", version = "0.0.11")
bazel_dep(name = "rules_cc", version = "0.2.0")

bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.7.1", dev_dependency = True)
bazel_dep(name = "bazelrc-preset.bzl", version = "1.6.0", dev_dependency = True)
bazel_dep(name = "buildifier_prebuilt", version = "8.2.1", dev_dependency = True)
bazel_dep(name = "gazelle", version = "0.42.0", dev_dependency = True, repo_name = "bazel_gazelle")
bazel_dep(name = "stardoc", version = "0.7.1", dev_dependency = True)

# Select first d toolchain available for the current platform.
d = use_extension("//d:extensions.bzl", "d")
d.toolchain(d_version = "dmd-2.111.0")
d.toolchain(d_version = "ldc-1.41.0")
use_repo(d, "d_toolchains")

register_toolchains("@d_toolchains//:all")
